//金额转换:2135  零佰零拾零万贰仟壹佰叁拾伍元
import java.util.Scanner;
public class A31{
	public static void main(String[] args){
		//输入一个金额
		Scanner sc = new Scanner(System.in);
		int money = 0;
		while(true){
			System.out.println("请输入一个金额");
			money = sc.nextInt();
			if(money >= 0 && money <= 9999999){
				break;
			}else{
				System.out.println("金额无效,请重新输入");
			}
		}
		//得到每一位数字
		String result = "";
		int count = 0;
		while(money != 0){
			int ge = money % 10;
			money = money / 10;
			result = getCapitalNumber(ge) + result;
			count++;
		}
		for(int i = 0;i < (7-count);i++){
			result = "零" + result;
		}
		String capitalMoney = "";
		for(int i = 0;i < 7;i++){
			capitalMoney = capitalMoney + result.charAt(i) + insertUnit(i);
		}
		System.out.println(capitalMoney);
	}
	public static String getCapitalNumber(int number){
		String[] arr = {"零","壹","贰","叁","肆","伍","陆","柒","捌","玖"};
		return arr[number];
	}
	public static String insertUnit(int number){
		String[] arr = {"佰","拾","万","仟","佰","拾","元"};
		return arr[number];
	}
}
